-- GENERATED SPELL FOR [Dragonmaw Wrangler] --


function spell0_21717(pUnit, Event) --@Enrage,Self--
pUnit:FullCastSpellOnTarget(8599,pUnit)
pUnit:RegisterEvent('Sorts_21717', 578, 1)
end

function spell1_21717(pUnit, Event) --@Net,n/a--
pUnit:FullCastSpellOnTarget(38338,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_21717', 5268, 1)
end

function Sorts_21717(pUnit, Event)
local choix_sorts_21717 = math.random(0, 1)
if choix_sorts_21717 == 0 then
pUnit:RegisterEvent('spell0_21717', 1, 1)
end
if choix_sorts_21717 == 1 then
pUnit:RegisterEvent('spell1_21717', 1, 1)
end
end

function mob21717_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_21717', math.random(1500, 3000), 1)
end

function mob21717_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob21717_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob21717_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(21717, 1, 'mob21717_Action')
RegisterUnitEvent(21717, 2, 'mob21717_Leave')
RegisterUnitEvent(21717, 3, 'mob21717_Kill')
RegisterUnitEvent(21717, 4, 'mob21717_Die')
